<%--
  Created by IntelliJ IDEA.
  User: Administrator
  Date: 2018/2/3 0003
  Time: 10:05
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<!-- 侧面菜单栏 -->
<link rel="stylesheet" href="${requestScope.webRoot}static/bootstrap/sidebarMenu/sidebar-menu.css" />
<link rel="stylesheet" href="${requestScope.webRoot}static/bootstrap/font/font-awesome.min.css" />
<script src="${requestScope.webRoot}static/bootstrap/sidebarMenu/sidebar-menu.js"></script>
<!-- 复选框样式 -->
<script src="${requestScope.webRoot}static/bootstrap/checkbox/bootstrap-checkbox.min.js"></script>

<div class="leftTheBorder">
    <aside class="main-sidebar">
        <section  class="sidebar">
            <div id="toggle-sidebar">
                <div></div>
                <div></div>
                <div></div>
            </div>
            <ul class="sidebar-menu">
                <li class="header ">超盟</li>
                <li class="food">
                    <a href="javascript:return false;">
                        <i class="fa fa-dashboard"></i><span>商品</span><i class="fa fa-angle-left pull-right"></i>
                    </a>
                    <ul class="treeview-menu">
                        <%--<li class="foodSales"><a href='${requestScope.webRoot}admin/foodSales'>食品销量</a></li>--%>
                        <li class="orders"><a href='${requestScope.webRoot}admin/orders'>订单</a></li>
                        <li class="foods"><a href='${requestScope.webRoot}admin/foods'>商品清单</a></li>
                        <li class="foodtype"><a href='${requestScope.webRoot}admin/foodtype'>商品类型</a></li>
                    </ul>
                </li>
            </ul>
        </section>
    </aside>
</div>
<script>
    $(function () {
        var level1Menu = "<%=request.getParameter("level1Menu")%>";
        var level2Menu = "<%=request.getParameter("level2Menu")%>";
        $.sidebarMenu($(".leftTheBorder"));
        var $select =  $("."+level1Menu);

        $select.addClass("active");

        if(level2Menu != ""){
            var $select2 = $select.find("."+level2Menu);
            if($select2){
                $select2.addClass("active");
            }
        }
    });
</script>
